<template>
    <div class="index-lists">
        <el-card class="!border-none" shadow="never">
            <el-form ref="formRef" class="mb-[-16px]" :model="queryParams" :inline="true">
                <el-form-item label="客户编号" prop="customerId">
                    <el-input class="w-[280px]" v-model="queryParams.customerId" />
                </el-form-item>
                <el-form-item label="案件类型" prop="caseType">
                    <el-select v-model="queryParams.caseType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="客户代码" prop="customerCode">
                    <el-input class="w-[280px]" v-model="queryParams.customerCode" />
                </el-form-item>

                <el-form-item label="客户名称(英)" prop="customerNameEnglish">
                    <el-input class="w-[280px]" v-model="queryParams.customerNameEnglish" />
                </el-form-item>
                <el-form-item label="客户网址" prop="customerWebsite">
                    <el-input class="w-[280px]" v-model="queryParams.customerWebsite" />
                </el-form-item>
                <el-form-item label="公司负责人" prop="companyOfficials">
                    <el-input class="w-[280px]" v-model="queryParams.companyOfficials" />
                </el-form-item>
                <el-form-item label="所属行业编号" prop="industryInvolvedId">
                    <el-input class="w-[280px]" v-model="queryParams.industryInvolvedId" />
                </el-form-item>
                <el-form-item label="所属行业" prop="industryInvolved">
                    <el-input class="w-[280px]" v-model="queryParams.industryInvolved" />
                </el-form-item>
                <el-form-item label="业务合作编号" prop="businessCooperationId">
                    <el-input class="w-[280px]" v-model="queryParams.businessCooperationId" />
                </el-form-item>
                <el-form-item label="业务合作" prop="businessCooperation">
                    <el-input class="w-[280px]" v-model="queryParams.businessCooperation" />
                </el-form-item>
                <el-form-item label="业务人员编号" prop="businessPersonnelId">
                    <el-input class="w-[280px]" v-model="queryParams.businessPersonnelId" />
                </el-form-item>
                <el-form-item label="业务人员" prop="businessPersonnel">
                    <el-input class="w-[280px]" v-model="queryParams.businessPersonnel" />
                </el-form-item>
                <el-form-item label="业务助理编号" prop="businessAssistantId">
                    <el-input class="w-[280px]" v-model="queryParams.businessAssistantId" />
                </el-form-item>
                <el-form-item label="业务助理" prop="businessAssistant">
                    <el-input class="w-[280px]" v-model="queryParams.businessAssistant" />
                </el-form-item>
                <el-form-item label="流程人员编号" prop="processPersonnelId">
                    <el-input class="w-[280px]" v-model="queryParams.processPersonnelId" />
                </el-form-item>
                <el-form-item label="流程人员" prop="processPersonnel">
                    <el-input class="w-[280px]" v-model="queryParams.processPersonnel" />
                </el-form-item>
                <el-form-item label="所属分部编号" prop="subdivisionId">
                    <el-input class="w-[280px]" v-model="queryParams.subdivisionId" />
                </el-form-item>
                <el-form-item label="所属分部" prop="subdivision">
                    <el-input class="w-[280px]" v-model="queryParams.subdivision" />
                </el-form-item>
                <el-form-item label="客户签约日期" prop="contractedCustomerTime">
                    <el-input class="w-[280px]" v-model="queryParams.contractedCustomerTime" />
                </el-form-item>
                <el-form-item label="成交状态" prop="makebargainStatus">
                    <el-select v-model="queryParams.makebargainStatus" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="创建日期" prop="basicsCreateTime">
                    <el-input class="w-[280px]" v-model="queryParams.basicsCreateTime" />
                </el-form-item>
                <!-- <el-form-item label="创建人" prop="basicsCreateName">
          <el-input class="w-[280px]" v-model="queryParams.basicsCreateName" />
        </el-form-item> -->
                <el-form-item label="协作人编号" prop="associatesId">
                    <el-input class="w-[280px]" v-model="queryParams.associatesId" />
                </el-form-item>
                <el-form-item label="协作人" prop="associates">
                    <el-input class="w-[280px]" v-model="queryParams.associates" />
                </el-form-item>
                <el-form-item label="案源公司编号" prop="caseSourceCompanyId">
                    <el-input class="w-[280px]" v-model="queryParams.caseSourceCompanyId" />
                </el-form-item>
                <el-form-item label="案源公司" prop="caseSourceCompany">
                    <el-input class="w-[280px]" v-model="queryParams.caseSourceCompany" />
                </el-form-item>
                <el-form-item label="代理等级编号" prop="agencyGradeId">
                    <el-input class="w-[280px]" v-model="queryParams.agencyGradeId" />
                </el-form-item>
                <el-form-item label="代理等级" prop="agencyGrade">
                    <el-select v-model="queryParams.agencyGrade" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="客户规模编号" prop="customerSizeId">
                    <el-input class="w-[280px]" v-model="queryParams.customerSizeId" />
                </el-form-item>
                <el-form-item label="客户规模" prop="customerSize">
                    <el-input class="w-[280px]" v-model="queryParams.customerSize" />
                </el-form-item>
                <el-form-item label="非主力代理人编号" prop="nonPrincipalAgentId">
                    <el-input class="w-[280px]" v-model="queryParams.nonPrincipalAgentId" />
                </el-form-item>
                <el-form-item label="非主力代理人" prop="nonPrincipalAgent">
                    <el-input class="w-[280px]" v-model="queryParams.nonPrincipalAgent" />
                </el-form-item>
                <el-form-item label="更新人员编号" prop="uploadsUserId">
                    <el-input class="w-[280px]" v-model="queryParams.uploadsUserId" />
                </el-form-item>
                <el-form-item label="更新人员" prop="uploadsUserName">
                    <el-input class="w-[280px]" v-model="queryParams.uploadsUserName" />
                </el-form-item>
                <el-form-item label="修改时间" prop="uploadsTime">
                    <el-input class="w-[280px]" v-model="queryParams.uploadsTime" />
                </el-form-item>
                <el-form-item label="客户系统ip" prop="clientIp">
                    <el-input class="w-[280px]" v-model="queryParams.clientIp" />
                </el-form-item>
                <el-form-item label="客户系统账号" prop="clientAccount">
                    <el-input class="w-[280px]" v-model="queryParams.clientAccount" />
                </el-form-item>
                <el-form-item label="备注" prop="remark">
                    <el-input class="w-[280px]" v-model="queryParams.remark" />
                </el-form-item>
                <el-form-item label="联系方式" prop="contactInformation">
                    <el-input class="w-[280px]" v-model="queryParams.contactInformation" />
                </el-form-item>
                <el-form-item label="昵称" prop="nickname">
                    <el-input class="w-[280px]" v-model="queryParams.nickname" />
                </el-form-item>
                <el-form-item label="电话" prop="phone">
                    <el-input class="w-[280px]" v-model="queryParams.phone" />
                </el-form-item>
                <el-form-item label="传真" prop="fax">
                    <el-input class="w-[280px]" v-model="queryParams.fax" />
                </el-form-item>
                <el-form-item label="邮件" prop="email">
                    <el-input class="w-[280px]" v-model="queryParams.email" />
                </el-form-item>
                <el-form-item label="邮编" prop="postcode">
                    <el-input class="w-[280px]" v-model="queryParams.postcode" />
                </el-form-item>
                <el-form-item label="客户等级编号" prop="clientGradeId">
                    <el-input class="w-[280px]" v-model="queryParams.clientGradeId" />
                </el-form-item>
                <el-form-item label="客户等级" prop="clientGrade">
                    <el-select v-model="queryParams.clientGrade" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="信誉等级编号" prop="reputationGradeId">
                    <el-input class="w-[280px]" v-model="queryParams.reputationGradeId" />
                </el-form-item>
                <el-form-item label="信誉等级" prop="reputationGrade">
                    <el-select v-model="queryParams.reputationGrade" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="保密等级编号" prop="confidentialityGradeId">
                    <el-input class="w-[280px]" v-model="queryParams.confidentialityGradeId" />
                </el-form-item>
                <el-form-item label="保密等级" prop="confidentialityGrade">
                    <el-select
                        v-model="queryParams.confidentialityGrade"
                        class="w-[280px]"
                        clearable
                    >
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="客户来源编号" prop="customerSourceId">
                    <el-input class="w-[280px]" v-model="queryParams.customerSourceId" />
                </el-form-item>
                <el-form-item label="客户来源" prop="customerSource">
                    <el-input class="w-[280px]" v-model="queryParams.customerSource" />
                </el-form-item>
                <el-form-item label="客户镇区编号" prop="customerTownshipId">
                    <el-input class="w-[280px]" v-model="queryParams.customerTownshipId" />
                </el-form-item>
                <el-form-item label="客户镇区" prop="customerTownship">
                    <el-input class="w-[280px]" v-model="queryParams.customerTownship" />
                </el-form-item>
                <el-form-item label="客户园区编号" prop="customerGardenId">
                    <el-input class="w-[280px]" v-model="queryParams.customerGardenId" />
                </el-form-item>
                <el-form-item label="客户园区" prop="customerGarden">
                    <el-input class="w-[280px]" v-model="queryParams.customerGarden" />
                </el-form-item>
                <el-form-item label="客户类型编号" prop="customerTypeId">
                    <el-input class="w-[280px]" v-model="queryParams.customerTypeId" />
                </el-form-item>
                <el-form-item label="客户类型" prop="customerType">
                    <el-select v-model="queryParams.customerType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="内部案源人" prop="internalSource">
                    <el-input class="w-[280px]" v-model="queryParams.internalSource" />
                </el-form-item>
                <el-form-item label="内部案源人电话" prop="internalSourcePhone">
                    <el-input class="w-[280px]" v-model="queryParams.internalSourcePhone" />
                </el-form-item>
                <el-form-item label="内部案源人邮箱" prop="internalSourceEmail">
                    <el-input class="w-[280px]" v-model="queryParams.internalSourceEmail" />
                </el-form-item>
                <el-form-item label="外部案源人" prop="externalCaseSource">
                    <el-input class="w-[280px]" v-model="queryParams.externalCaseSource" />
                </el-form-item>
                <el-form-item label="外部案源人电话" prop="externalCasePhone">
                    <el-input class="w-[280px]" v-model="queryParams.externalCasePhone" />
                </el-form-item>
                <el-form-item label="外部案源人邮箱" prop="externalCaseEmail">
                    <el-input class="w-[280px]" v-model="queryParams.externalCaseEmail" />
                </el-form-item>
                <el-form-item label="案源类型编号" prop="sourceTypeId">
                    <el-input class="w-[280px]" v-model="queryParams.sourceTypeId" />
                </el-form-item>
                <el-form-item label="案源类型" prop="sourceType">
                    <el-select v-model="queryParams.sourceType" class="w-[280px]" clearable>
                        <el-option label="请选择字典生成" value="" />
                    </el-select>
                </el-form-item>
                <el-form-item label="账单地址" prop="billingAddress">
                    <el-input class="w-[280px]" v-model="queryParams.billingAddress" />
                </el-form-item>
                <el-form-item label="缴费抬头" prop="paymentTitle">
                    <el-input class="w-[280px]" v-model="queryParams.paymentTitle" />
                </el-form-item>
                <el-form-item label="纳税人识别号(信用代码)" prop="identificationNumberTaxpayer">
                    <el-input
                        class="w-[280px]"
                        v-model="queryParams.identificationNumberTaxpayer"
                    />
                </el-form-item>
                <el-form-item label="发票抬头" prop="invoiceTitle">
                    <el-input class="w-[280px]" v-model="queryParams.invoiceTitle" />
                </el-form-item>
                <el-form-item label="开户银行" prop="depositBank">
                    <el-input class="w-[280px]" v-model="queryParams.depositBank" />
                </el-form-item>
                <el-form-item label="银行账号" prop="bankAccount">
                    <el-input class="w-[280px]" v-model="queryParams.bankAccount" />
                </el-form-item>
                <el-form-item label="年度销售收入" prop="annualSalesRevenue">
                    <el-input class="w-[280px]" v-model="queryParams.annualSalesRevenue" />
                </el-form-item>
                <el-form-item label="一般纳税人" prop="generalTaxpayer">
                    <el-input class="w-[280px]" v-model="queryParams.generalTaxpayer" />
                </el-form-item>
                <el-form-item label="代理费折扣率" prop="agencyDiscountRate">
                    <el-input class="w-[280px]" v-model="queryParams.agencyDiscountRate" />
                </el-form-item>
                <el-form-item label="开户名称" prop="accountName">
                    <el-input class="w-[280px]" v-model="queryParams.accountName" />
                </el-form-item>
                <el-form-item label="总资产" prop="totalAssets">
                    <el-input class="w-[280px]" v-model="queryParams.totalAssets" />
                </el-form-item>
                <el-form-item label="电话信息" prop="phoneInfo">
                    <el-input class="w-[280px]" v-model="queryParams.phoneInfo" />
                </el-form-item>
                <el-form-item label="国家(地区)" prop="nation">
                    <el-input class="w-[280px]" v-model="queryParams.nation" />
                </el-form-item>
                <el-form-item label="省份" prop="province">
                    <el-input class="w-[280px]" v-model="queryParams.province" />
                </el-form-item>
                <el-form-item label="城市(中文)" prop="cityChinese">
                    <el-input class="w-[280px]" v-model="queryParams.cityChinese" />
                </el-form-item>
                <el-form-item label="行政区划" prop="administrativeDivision">
                    <el-input class="w-[280px]" v-model="queryParams.administrativeDivision" />
                </el-form-item>
                <el-form-item label="经营地址" prop="businessAddress">
                    <el-input class="w-[280px]" v-model="queryParams.businessAddress" />
                </el-form-item>
                <el-form-item label="经营电话" prop="businessPhone">
                    <el-input class="w-[280px]" v-model="queryParams.businessPhone" />
                </el-form-item>
                <el-form-item label="地址" prop="addressChinese">
                    <el-input class="w-[280px]" v-model="queryParams.addressChinese" />
                </el-form-item>
                <el-form-item label="英文地址" prop="addressEnglish">
                    <el-input class="w-[280px]" v-model="queryParams.addressEnglish" />
                </el-form-item>
                <el-form-item label="其他地址" prop="additionalAddress">
                    <el-input class="w-[280px]" v-model="queryParams.additionalAddress" />
                </el-form-item>
                <el-form-item label="专利数量" prop="patentQuantity">
                    <el-input class="w-[280px]" v-model="queryParams.patentQuantity" />
                </el-form-item>
                <el-form-item label="商标数量" prop="numberOfTrademarks">
                    <el-input class="w-[280px]" v-model="queryParams.numberOfTrademarks" />
                </el-form-item>
                <el-form-item label="版权数量" prop="copyrightNumber">
                    <el-input class="w-[280px]" v-model="queryParams.copyrightNumber" />
                </el-form-item>
                <el-form-item label="评估依据" prop="evaluationBasis">
                    <el-input class="w-[280px]" v-model="queryParams.evaluationBasis" />
                </el-form-item>
                <el-form-item label="跟进时间" prop="followUpTime">
                    <el-input class="w-[280px]" v-model="queryParams.followUpTime" />
                </el-form-item>
                <el-form-item label="X天未跟进id" prop="unfollowedId">
                    <el-input class="w-[280px]" v-model="queryParams.unfollowedId" />
                </el-form-item>
                <el-form-item label="X天未跟进" prop="unfollowed">
                    <el-input class="w-[280px]" v-model="queryParams.unfollowed" />
                </el-form-item>
                <el-form-item label="修改人编号" prop="updateUserId">
                    <el-input class="w-[280px]" v-model="queryParams.updateUserId" />
                </el-form-item>
                <el-form-item>
                    <el-button type="primary" @click="resetPage">查询</el-button>
                    <el-button @click="resetParams">重置</el-button>
                </el-form-item>
            </el-form>
        </el-card>
        <el-card class="!border-none mt-4" shadow="never">
            <div>
                <el-button v-perms="['customerlist:add']" type="primary" @click="handleAdd()">
                    <template #icon>
                        <icon name="el-icon-Plus" />
                    </template>
                    新增
                </el-button>
            </div>
            <el-table class="mt-4" size="large" v-loading="pager.loading" :data="pager.lists">
                <el-table-column label="客户编号" prop="customerId" min-width="100" />
                <el-table-column label="案件类型" prop="caseType" min-width="100" />
                <el-table-column label="客户代码" prop="customerCode" min-width="100" />
                <el-table-column label="客户名称(中)" prop="customerNameChinese" min-width="100" />
                <el-table-column label="客户名称(英)" prop="customerNameEnglish" min-width="100" />
                <el-table-column label="客户网址" prop="customerWebsite" min-width="100" />
                <el-table-column label="公司负责人" prop="companyOfficials" min-width="100" />
                <el-table-column label="所属行业编号" prop="industryInvolvedId" min-width="100" />
                <el-table-column label="所属行业" prop="industryInvolved" min-width="100" />
                <el-table-column
                    label="业务合作编号"
                    prop="businessCooperationId"
                    min-width="100"
                />
                <el-table-column label="业务合作" prop="businessCooperation" min-width="100" />
                <el-table-column label="业务人员编号" prop="businessPersonnelId" min-width="100" />
                <el-table-column label="业务人员" prop="businessPersonnel" min-width="100" />
                <el-table-column label="业务助理编号" prop="businessAssistantId" min-width="100" />
                <el-table-column label="业务助理" prop="businessAssistant" min-width="100" />
                <el-table-column label="流程人员编号" prop="processPersonnelId" min-width="100" />
                <el-table-column label="流程人员" prop="processPersonnel" min-width="100" />
                <el-table-column label="所属分部编号" prop="subdivisionId" min-width="100" />
                <el-table-column label="所属分部" prop="subdivision" min-width="100" />
                <el-table-column
                    label="客户签约日期"
                    prop="contractedCustomerTime"
                    min-width="100"
                />
                <el-table-column label="成交状态" prop="makebargainStatus" min-width="100" />
                <el-table-column label="创建日期" prop="basicsCreateTime" min-width="100" />
                <el-table-column label="创建人" prop="basicsCreateName" min-width="100" />
                <el-table-column label="协作人编号" prop="associatesId" min-width="100" />
                <el-table-column label="协作人" prop="associates" min-width="100" />
                <el-table-column label="案源公司编号" prop="caseSourceCompanyId" min-width="100" />
                <el-table-column label="案源公司" prop="caseSourceCompany" min-width="100" />
                <el-table-column label="代理等级编号" prop="agencyGradeId" min-width="100" />
                <el-table-column label="代理等级" prop="agencyGrade" min-width="100" />
                <el-table-column label="客户规模编号" prop="customerSizeId" min-width="100" />
                <el-table-column label="客户规模" prop="customerSize" min-width="100" />
                <el-table-column
                    label="非主力代理人编号"
                    prop="nonPrincipalAgentId"
                    min-width="100"
                />
                <el-table-column label="非主力代理人" prop="nonPrincipalAgent" min-width="100" />
                <el-table-column label="更新人员编号" prop="uploadsUserId" min-width="100" />
                <el-table-column label="更新人员" prop="uploadsUserName" min-width="100" />
                <el-table-column label="修改时间" prop="uploadsTime" min-width="100" />
                <el-table-column label="客户系统ip" prop="clientIp" min-width="100" />
                <el-table-column label="客户系统账号" prop="clientAccount" min-width="100" />
                <el-table-column label="备注" prop="remark" min-width="100" />
                <el-table-column label="联系方式" prop="contactInformation" min-width="100" />
                <el-table-column label="昵称" prop="nickname" min-width="100" />
                <el-table-column label="电话" prop="phone" min-width="100" />
                <el-table-column label="传真" prop="fax" min-width="100" />
                <el-table-column label="邮件" prop="email" min-width="100" />
                <el-table-column label="邮编" prop="postcode" min-width="100" />
                <el-table-column label="客户等级编号" prop="clientGradeId" min-width="100" />
                <el-table-column label="客户等级" prop="clientGrade" min-width="100" />
                <el-table-column label="信誉等级编号" prop="reputationGradeId" min-width="100" />
                <el-table-column label="信誉等级" prop="reputationGrade" min-width="100" />
                <el-table-column
                    label="保密等级编号"
                    prop="confidentialityGradeId"
                    min-width="100"
                />
                <el-table-column label="保密等级" prop="confidentialityGrade" min-width="100" />
                <el-table-column label="客户来源编号" prop="customerSourceId" min-width="100" />
                <el-table-column label="客户来源" prop="customerSource" min-width="100" />
                <el-table-column label="客户镇区编号" prop="customerTownshipId" min-width="100" />
                <el-table-column label="客户镇区" prop="customerTownship" min-width="100" />
                <el-table-column label="客户园区编号" prop="customerGardenId" min-width="100" />
                <el-table-column label="客户园区" prop="customerGarden" min-width="100" />
                <el-table-column label="客户类型编号" prop="customerTypeId" min-width="100" />
                <el-table-column label="客户类型" prop="customerType" min-width="100" />
                <el-table-column label="内部案源人" prop="internalSource" min-width="100" />
                <el-table-column
                    label="内部案源人电话"
                    prop="internalSourcePhone"
                    min-width="100"
                />
                <el-table-column
                    label="内部案源人邮箱"
                    prop="internalSourceEmail"
                    min-width="100"
                />
                <el-table-column label="外部案源人" prop="externalCaseSource" min-width="100" />
                <el-table-column label="外部案源人电话" prop="externalCasePhone" min-width="100" />
                <el-table-column label="外部案源人邮箱" prop="externalCaseEmail" min-width="100" />
                <el-table-column label="案源类型编号" prop="sourceTypeId" min-width="100" />
                <el-table-column label="案源类型" prop="sourceType" min-width="100" />
                <el-table-column label="账单地址" prop="billingAddress" min-width="100" />
                <el-table-column label="缴费抬头" prop="paymentTitle" min-width="100" />
                <el-table-column
                    label="纳税人识别号(信用代码)"
                    prop="identificationNumberTaxpayer"
                    min-width="100"
                />
                <el-table-column label="发票抬头" prop="invoiceTitle" min-width="100" />
                <el-table-column label="开户银行" prop="depositBank" min-width="100" />
                <el-table-column label="银行账号" prop="bankAccount" min-width="100" />
                <el-table-column label="年度销售收入" prop="annualSalesRevenue" min-width="100" />
                <el-table-column label="一般纳税人" prop="generalTaxpayer" min-width="100" />
                <el-table-column label="代理费折扣率" prop="agencyDiscountRate" min-width="100" />
                <el-table-column label="开户名称" prop="accountName" min-width="100" />
                <el-table-column label="总资产" prop="totalAssets" min-width="100" />
                <el-table-column label="电话信息" prop="phoneInfo" min-width="100" />
                <el-table-column label="国家(地区)" prop="nation" min-width="100" />
                <el-table-column label="省份" prop="province" min-width="100" />
                <el-table-column label="城市(中文)" prop="cityChinese" min-width="100" />
                <el-table-column label="行政区划" prop="administrativeDivision" min-width="100" />
                <el-table-column label="经营地址" prop="businessAddress" min-width="100" />
                <el-table-column label="经营电话" prop="businessPhone" min-width="100" />
                <el-table-column label="地址" prop="addressChinese" min-width="100" />
                <el-table-column label="英文地址" prop="addressEnglish" min-width="100" />
                <el-table-column label="其他地址" prop="additionalAddress" min-width="100" />
                <el-table-column label="专利数量" prop="patentQuantity" min-width="100" />
                <el-table-column label="商标数量" prop="numberOfTrademarks" min-width="100" />
                <el-table-column label="版权数量" prop="copyrightNumber" min-width="100" />
                <el-table-column label="评估依据" prop="evaluationBasis" min-width="100" />
                <el-table-column label="跟进时间" prop="followUpTime" min-width="100" />
                <el-table-column label="X天未跟进id" prop="unfollowedId" min-width="100" />
                <el-table-column label="X天未跟进" prop="unfollowed" min-width="100" />
                <el-table-column label="修改人编号" prop="updateUserId" min-width="100" />
                <el-table-column label="创建时间" prop="createTime" min-width="100" />
                <el-table-column label="操作" width="120" fixed="right">
                    <template #default="{ row }">
                        <el-button
                            v-perms="['customerlist:edit']"
                            type="primary"
                            link
                            @click="handleEdit(row)"
                        >
                            编辑
                        </el-button>
                        <el-button
                            v-perms="['customerlist:del']"
                            type="danger"
                            link
                            @click="handleDelete(row.id)"
                        >
                            删除
                        </el-button>
                    </template>
                </el-table-column>
            </el-table>
            <div class="flex justify-end mt-4">
                <pagination v-model="pager" @change="getLists" />
            </div>
        </el-card>
        <edit-popup v-if="showEdit" ref="editRef" @success="getLists" @close="showEdit = false" />
    </div>
</template>
<script lang="ts" setup name="customerlist">
import { customerColDelete, customerColList } from '@/api/customer/customerColList'
import { usePaging } from '@/hooks/usePaging'
import feedback from '@/utils/feedback'
import EditPopup from './edit.vue'
const editRef = shallowRef<InstanceType<typeof EditPopup>>()
const showEdit = ref(false)
const queryParams = reactive({
    customerId: '',
    caseType: '',
    customerCode: '',
    customerNameChinese: '',
    customerNameEnglish: '',
    customerWebsite: '',
    companyOfficials: '',
    industryInvolvedId: '',
    industryInvolved: '',
    businessCooperationId: '',
    businessCooperation: '',
    businessPersonnelId: '',
    businessPersonnel: '',
    businessAssistantId: '',
    businessAssistant: '',
    processPersonnelId: '',
    processPersonnel: '',
    subdivisionId: '',
    subdivision: '',
    contractedCustomerTime: '',
    makebargainStatus: '',
    basicsCreateTime: '',
    basicsCreateName: '',
    associatesId: '',
    associates: '',
    caseSourceCompanyId: '',
    caseSourceCompany: '',
    agencyGradeId: '',
    agencyGrade: '',
    customerSizeId: '',
    customerSize: '',
    nonPrincipalAgentId: '',
    nonPrincipalAgent: '',
    uploadsUserId: '',
    uploadsUserName: '',
    uploadsTime: '',
    clientIp: '',
    clientAccount: '',
    remark: '',
    contactInformation: '',
    nickname: '',
    phone: '',
    fax: '',
    email: '',
    postcode: '',
    clientGradeId: '',
    clientGrade: '',
    reputationGradeId: '',
    reputationGrade: '',
    confidentialityGradeId: '',
    confidentialityGrade: '',
    customerSourceId: '',
    customerSource: '',
    customerTownshipId: '',
    customerTownship: '',
    customerGardenId: '',
    customerGarden: '',
    customerTypeId: '',
    customerType: '',
    internalSource: '',
    internalSourcePhone: '',
    internalSourceEmail: '',
    externalCaseSource: '',
    externalCasePhone: '',
    externalCaseEmail: '',
    sourceTypeId: '',
    sourceType: '',
    billingAddress: '',
    paymentTitle: '',
    identificationNumberTaxpayer: '',
    invoiceTitle: '',
    depositBank: '',
    bankAccount: '',
    annualSalesRevenue: '',
    generalTaxpayer: '',
    agencyDiscountRate: '',
    accountName: '',
    totalAssets: '',
    phoneInfo: '',
    nation: '',
    province: '',
    cityChinese: '',
    administrativeDivision: '',
    businessAddress: '',
    businessPhone: '',
    addressChinese: '',
    addressEnglish: '',
    additionalAddress: '',
    patentQuantity: '',
    numberOfTrademarks: '',
    copyrightNumber: '',
    evaluationBasis: '',
    followUpTime: '',
    unfollowedId: '',
    unfollowed: '',
    updateUserId: ''
})

const { pager, getLists, resetPage, resetParams } = usePaging({
    fetchFun: customerColList,
    params: queryParams
})

const handleAdd = async () => {
    showEdit.value = true
    await nextTick()
    editRef.value?.open('add')
}

const handleEdit = async (data: any) => {
    showEdit.value = true
    await nextTick()
    editRef.value?.open('edit')
    editRef.value?.getDetail(data)
}

const handleDelete = async (id: number) => {
    await feedback.confirm('确定要删除？')
    await customerColDelete({ id })
    feedback.msgSuccess('删除成功')
    getLists()
}

getLists()
</script>
